package com.siam.package_user.service;

import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.siam.package_user.entity.Member;
import com.siam.package_user.entity.MemberWithdrawRecord;
import com.siam.package_user.model.param.MemberWithdrawRecordParam;

import java.util.Map;

/**
 *  高品
 */
public interface MemberWithdrawRecordService extends IService<MemberWithdrawRecord> {

    void deleteByPrimaryKey(Integer id);

    void insert(MemberWithdrawRecordParam param);

    MemberWithdrawRecord selectByPrimaryKey(Integer id);

    void updateByPrimaryKeySelective(MemberWithdrawRecord memberWithdrawRecord);

    Page getListByPage(MemberWithdrawRecordParam param);

    Page getListByPageJoinMember(MemberWithdrawRecordParam param);

    Map<String, Object> statisticalAmount(MemberWithdrawRecordParam param);

    void autoPayment();

    /**
     * 审核申请体现用户信息
     *
     * @return
     * @author 高品
     */
    void auditApplyWithdraw(MemberWithdrawRecordParam param);

    /**
     * 获取提现确认收款弹窗需要的信息
     * @return
     */
    JSONObject getRequestMerchantTransferParams();

    /**
     * 提现失败后置处理
     * @param dbMemberWithdrawRecord
     * @param dbMember
     */
    void handleWithdrawFail(MemberWithdrawRecord dbMemberWithdrawRecord, Member dbMember);
}